package com.xueyi.workflow.event;

import org.springframework.context.ApplicationEvent;

/**
 * 流程完成事件
 * 当流程实例完成时发布此事件
 *
 * @author xueyi
 * @date 2024-08-26
 */
public class ProcessCompletedEvent extends ApplicationEvent {
    
    private final String processInstanceId;
    private final String businessKey;
    private final String processDefinitionKey;
    
    public ProcessCompletedEvent(Object source, String processInstanceId, String businessKey, String processDefinitionKey) {
        super(source);
        this.processInstanceId = processInstanceId;
        this.businessKey = businessKey;
        this.processDefinitionKey = processDefinitionKey;
    }
    
    public String getProcessInstanceId() {
        return processInstanceId;
    }
    
    public String getBusinessKey() {
        return businessKey;
    }
    
    public String getProcessDefinitionKey() {
        return processDefinitionKey;
    }
}
